﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace day2_case1
{
    internal class Program
    {

        static int a = 50;
        static void Main(string[] args)
        {
            //int a, b, c;
            //a = 2;
            //b = 3;
            //c = a + b;
            //Console.WriteLine(c);
            //Console.Read();


            //if (a <= 60)
            //{
            //    string str = "通过";  // str是局部变量，只能在括号里面使用
            //    Console.WriteLine(str);
            //}
            ////Console.WriteLine(str);   //在括号外面使用无效

            //const double Pi= 3.14;
            //int r = 3;
            //double s=Pi*r*r;
            //Console.WriteLine(s);

            //int a = 100;
            //int b = 200;
            //Console.WriteLine("a==b is {0}", a == b);
            //Console.WriteLine("a<b is {0}", a < b);
            //Console.Read();

            //int a = 2;  // 0010
            //int b = 3;  //0011
            //Console.WriteLine("a is {0}", a);
            //Console.WriteLine("b is {0}", b);
            //int c = a & b;
            //Console.WriteLine("a&b is {0}", a & b);
            //c = a | b;
            //Console.WriteLine("a|b is {0}", a | b);
            //c = a ^ b;
            //Console.WriteLine("a^b is {0}", c);
            //c = ~a;
            //Console.WriteLine("~a is {0}", c);
            //// 0010取反是1101，是负数，负数在计算机补码存储，不包括符号位，取反加一得到1011是负数，就是-3
            //Console.Read();

            //double pay = 6000;
            //Console.WriteLine("税前工资pay{0}",pay);
            //double tax = pay >= 2000 ? (pay - 2000) * 0.1 : 0;
            //pay = pay - tax;
            //Console.WriteLine("税后工资pay{0}", pay);
            //Console.Read();



            Console.WriteLine("请输入一个1-12的月份：");
            int mon = int.Parse(Console.ReadLine());
            //int mon = DateTime.Now.Month;
            Console.WriteLine("当前月份{0}", mon);
            switch (mon)
            {
                case 12:
                case 1:
                case 2:
                    Console.WriteLine("现在是冬天 ");
                    Console.Read();
                    break;
                case 3:
                case 4:
                case 5:
                    Console.WriteLine("现在是春天 ");
                    Console.Read(); 
                    break;
                case 6:
                case 7:
                case 8:
                    Console.WriteLine("现在是夏天 ");
                    Console.Read(); break;
                case 9:
                case 10:
                case 11:
                    Console.WriteLine("现在是秋天 ");
                    Console.Read(); break;
                default:
                    Console.WriteLine("当前系统时间错误");break;
            }
            
            
        }
    }
}
